Optimal. Leaf size=37 \[ \frac {1}{4} \cos (2 a) \text {CosIntegral}\left (2 b x^2\right )+\frac {\log (x)}{2}-\frac {1}{4} \sin (2 a) \text {Si}\left (2 b x^2\right ) \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.04, antiderivative size = 37, normalized size of antiderivative = 1.00, number of steps
used = 5, number of rules used = 4, integrand size = 14, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.286, Rules used = {3485, 3459,
3457, 3456} \begin {gather*} \frac {1}{4} \cos (2 a) \text {CosIntegral}\left (2 b x^2\right )-\frac {1}{4} \sin (2 a) \text {Si}\left (2 b x^2\right )+\frac {\log (x)}{2} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 3456
Rule 3457
Rule 3459
Rule 3485
Rubi steps
\begin {align*} \int \frac {\cos ^2\left (a+b x^2\right )}{x} \, dx &=\int \left (\frac {1}{2 x}+\frac {\cos \left (2 a+2 b x^2\right )}{2 x}\right ) \, dx\\ &=\frac {\log (x)}{2}+\frac {1}{2} \int \frac {\cos \left (2 a+2 b x^2\right )}{x} \, dx\\ &=\frac {\log (x)}{2}+\frac {1}{2} \cos (2 a) \int \frac {\cos \left (2 b x^2\right )}{x} \, dx-\frac {1}{2} \sin (2 a) \int \frac {\sin \left (2 b x^2\right )}{x} \, dx\\ &=\frac {1}{4} \cos (2 a) \text {Ci}\left (2 b x^2\right )+\frac {\log (x)}{2}-\frac {1}{4} \sin (2 a) \text {Si}\left (2 b x^2\right )\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.04, size = 34, normalized size = 0.92 \begin {gather*} \frac {1}{4} \left (\cos (2 a) \text {CosIntegral}\left (2 b x^2\right )+2 \log (x)-\sin (2 a) \text {Si}\left (2 b x^2\right )\right ) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [C] Result contains higher order function than in optimal. Order 9 vs. order
4.
time = 0.13, size = 68, normalized size = 1.84
method | result | size |
risch | \(\frac {\ln \left (x \right )}{2}+\frac {i {\mathrm e}^{-2 i a} \pi \,\mathrm {csgn}\left (b \,x^{2}\right )}{8}-\frac {i {\mathrm e}^{-2 i a} \sinIntegral \left (2 b \,x^{2}\right )}{4}-\frac {{\mathrm e}^{-2 i a} \expIntegral \left (1, -2 i b \,x^{2}\right )}{8}-\frac {{\mathrm e}^{2 i a} \expIntegral \left (1, -2 i b \,x^{2}\right )}{8}\) | \(68\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [C] Result contains complex when optimal does not.
time = 0.37, size = 51, normalized size = 1.38 \begin {gather*} \frac {1}{8} \, {\left ({\rm Ei}\left (2 i \, b x^{2}\right ) + {\rm Ei}\left (-2 i \, b x^{2}\right )\right )} \cos \left (2 \, a\right ) + \frac {1}{8} \, {\left (i \, {\rm Ei}\left (2 i \, b x^{2}\right ) - i \, {\rm Ei}\left (-2 i \, b x^{2}\right )\right )} \sin \left (2 \, a\right ) + \frac {1}{2} \, \log \left (x\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.37, size = 39, normalized size = 1.05 \begin {gather*} \frac {1}{8} \, {\left (\operatorname {Ci}\left (2 \, b x^{2}\right ) + \operatorname {Ci}\left (-2 \, b x^{2}\right )\right )} \cos \left (2 \, a\right ) - \frac {1}{4} \, \sin \left (2 \, a\right ) \operatorname {Si}\left (2 \, b x^{2}\right ) + \frac {1}{2} \, \log \left (x\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \frac {\cos ^{2}{\left (a + b x^{2} \right )}}{x}\, dx \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 0.44, size = 35, normalized size = 0.95 \begin {gather*} \frac {1}{4} \, \cos \left (2 \, a\right ) \operatorname {Ci}\left (2 \, b x^{2}\right ) + \frac {1}{4} \, \sin \left (2 \, a\right ) \operatorname {Si}\left (-2 \, b x^{2}\right ) + \frac {1}{4} \, \log \left (b x^{2}\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.03 \begin {gather*} \int \frac {{\cos \left (b\,x^2+a\right )}^2}{x} \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________